The present invention relates to control networks utilizing a network protocol, and more specifically to the use of transaction identifiers for control network packets traveling in network which utilize the network protocol.
LonTalk(trademark) is a well known control network communications protocol designed for Local Area Network (LAN) type environments. This protocol can also be transported in an Internet protocol (IP) environment as well. FIG. 1A illustrates an IP network which is used to transport the LonTalk protocol. The network includes subnets 102 and 118, each with local nodes. Local nodes on one subnet 102 are able to communicate with nodes on the remote subnet 118 over the IP network 112. An exchange of information between nodes is carried out in a transaction. Each transaction involves at least one packet. For example, a sending node 104 on subnet 102 prepares a packet 106 addressed to the receiving node 120 on subnet 118. The sending node 104 assigns a Transaction Identifier (TID) to all packets of a certain transaction. In LonTalk, 4-bits are used for the TID, i.e., 16 possible TIDs are available. This packet 106 is forwarded to the sending router 108 which services the sending node""s subnet 102. The packet 106 is then transmitted to the receiving router 114 which services the subnet 118 containing the receiving node 120. The receiving router 114 then forwards the packet 106 to the receiving node 120.
At the receiving node 120, a transaction timer (receive timer) begins to run when a transaction begins. The receive transaction is active until the timer expires or a new transaction is started. Packets received containing the same TID while the transaction is active are assumed by the receiving node 120 to be part of the same transaction. Each time the receiving node 120 receives a packet 106, it may send to the sending node 104 an acknowledgment packet, which informs the sending node 104 that the packet 106 was actually received by the receiving node 104.
Occasionally, packets need to be retransmitted due to transmission errors and are given the same TID as the original packet. While the transaction is active, if the receiving node had already received the original packet, it will properly detect packets with the same TID to be duplicates. In LonTalk, the length of the transaction timer is set according to the possible delays in packet transmission in a LAN, which do not vary significantly. However, in an IP network, the delays can vary over a wider range and can be unpredictable. Thus, there is a problem in an IP network that packets become delayed such that they arrive after the expiration of the transaction timer. In this situation, the receiving node will not be able to recognize stale duplicate packets as such. It may mistakenly see the duplicate packet as indicating the beginning of a new transaction, resulting in erroneous functioning in the control network application.
Accordingly, there exists a need for a method to detect stale packets for reliable duplicate packet recognition for the control network. The present invention addresses such a need.
The present invention provides a method for reliable stale packet recognition in a network. The method includes: labeling a packet with a super transaction identifier (STID), the STID uniquely indicating a transaction; sending the packet with the STID to the receiving router; and blocking the sent packet from transmission to the receiving node if a transaction timer for the transaction indicated by the STID has expired. The method adds a STID to each packet. Each transaction is assigned a unique STID by the sending router, and each packet of the transaction is labeled with this STID. The receiving router uses the STID to block duplicate packets with the same STID which arrive after the expiration of the transaction timer. In this manner, stale packets are reliably detected by the receiving router.